import numpy as np
import pandas as pd
import os


#生成对象
a=pd.Series([1,3,5,np.nan,6,8])
#日期索引生成dataframe
dates=pd.date_range('20130101',periods=6)
df=pd.DataFrame(np.random.randn(6,4),index=dates,columns=list('ABCD'))
#Series字典对象生成DataFrame
df2=pd.DataFrame({
                'A':1.,
                'B':pd.Timestamp('20130102'),
                'C':pd.Series(1, index=list(range(4)), dtype='float32'),
                'D':np.array([3]*4,dtype='int'),
                'E':pd.Categorical(["test","train","test","train"]),
                'F':'foo'
})
#df2.to_excel('test.xlsx')


